const mongoose = require('mongoose')
const Schema = mongoose.Schema;
const { BaseParameter } = require('../base/model')

const FeedBackchema = new Schema({
  ...BaseParameter,
  /**
   * 反馈者名称
   */
  "name": {type: String, default: ''},
  /**
   * 反馈者手机号
   */
  "phone": {type: String, default: ''},
  /**
   * 反馈者QQ号
   */
  "qq": {type: String, default: ''},
  /**
   * 反馈者微信
   */
  "wx": {type: String, default: ''},
  /**
   * 是否显示在意见列表
   */
  "isShow": {type: Boolean, default: false},
  /**
   * 反馈时间
   */
  "date": {type: Date},
  /**
   * 反馈内容
   */
  "content": {type: String, default: ''},
  "reply": {
    "backDate": {type: Date},
    "backContent": {type: String, default: ''}
  }
});

const Feedback = mongoose.model('Feedback', FeedBackchema, 'feedbacks');

module.exports = Feedback
